package cg.studio.practise;

import java.util.Scanner;

/**
 * print "Fuzz" if line is 3, 6, 9 etc;
 * print "Buzz" if line is 5, 10 etc
 * print "FuzzBuzz" if line 15, 30 etc
 * other line print line number
 * 
 * @author Bright Chen
 *
 */
public class PrintFuzzBuzz
{
  public static void main( String[] argvs )
  {
    System.out.println( "Input Integer: " );
    try
    {
      Scanner in = new Scanner(System.in);
      int n = in.nextInt();
      
      for ( int i = 1; i <= n; ++i )
      {
        boolean printed = false;
        if ( i % 3 == 0 )
        {
          System.out.print( "Fuzz" );
          printed = true;
        }
        if ( i % 5 == 0 )
        {
          System.out.print( "Buzz" );
          printed = true;
        }
        if( printed )
          System.out.println( "" );
        else
          System.out.println( i );
      }
    }
    catch ( Exception e )
    {
      System.out.println( e.getMessage() );
    }

  }
}
